package cn.edu.yzu.scholarship.model;

import com.jfinal.ext.plugin.sqlinxml.SqlKit;
import com.jfinal.plugin.activerecord.Db;
import com.jfinal.plugin.activerecord.Model;
import com.jfinal.plugin.activerecord.Record;

public class Teacher extends Model<Teacher> {
	private static final long serialVersionUID = 8847297722065444080L;
	
	public static final Teacher dao = new Teacher();
	
	public static Record getTeacher(String loginName,String loginPwd) {
		return Db.findFirst(SqlKit.sql("teacher.findByLoginNameAndPwd"), loginName, loginPwd);
	}
	
	public static void update(Record record) {
		Db.update("teacher", record);
	}

}
